package com.study.demo01;

//代理角色
public class Proxy implements Rent {
    Host host = new Host();

    public Proxy() {
    }

    public Proxy(Host host) {
        this.host = host;
    }

    @Override
    public void rent() {
        seeHouse();
        host.rent();
        heTong();
        fare();
    }

    public void fare() {
        System.out.println("中介费");
    }

    public void seeHouse() {
        System.out.println("看房");
    }

    public void heTong() {
        System.out.println("签合同");
    }
}
